/*
 * @Author: tangyongxin 1463148307@qq.com
 * @Date: 2024-02-21 23:45:28
 * @LastEditors: tangyongxin 1463148307@qq.com
 * @LastEditTime: 2024-02-21 23:45:35
 * @FilePath: \patrol_front\src\api\resource\equipment.js
 * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
 */
import request from '@/utils/request'

// 查询设备信息列表
export function listEquipment(query) {
  return request({
    url: '/resource/equipment/list',
    method: 'get',
    params: query
  })
}

// 查询设备信息详细
export function getEquipment(id) {
  return request({
    url: '/resource/equipment/' + id,
    method: 'get'
  })
}

// 新增设备信息
export function addEquipment(data) {
  return request({
    url: '/resource/equipment',
    method: 'post',
    data: data
  })
}

// 修改设备信息
export function updateEquipment(data) {
  return request({
    url: '/resource/equipment',
    method: 'put',
    data: data
  })
}

// 删除设备信息
export function delEquipment(id) {
  return request({
    url: '/resource/equipment/' + id,
    method: 'delete'
  })
}
